﻿using System;
using Autodesk.Revit.ApplicationServices;
using Autodesk.Revit.Attributes;
using Autodesk.Revit.DB;
using Autodesk.Revit.UI;

namespace YJKCopyModel.InteractiveOperation.CmdTestInteractiveOperation
{
	[Transaction(TransactionMode.Manual)]
	[Regeneration(RegenerationOption.Manual)]
	public class CmdTestGetCurve : IExternalCommand
	{
		public Result Execute(ExternalCommandData commandData, ref string message, ElementSet elements)
		{
			Result result;
			try
			{
				TestInteractiveOperationInputRequestMaker useRequestMaker = new TestInteractiveOperationInputRequestMaker(commandData);
				QuickModelFrameWork quickModelFrameWork = new QuickModelFrameWork(useRequestMaker, null);
				quickModelFrameWork.Excute(commandData);
				result = Autodesk.Revit.UI.Result.Succeeded;
			}
			catch (Exception)
			{
				result = Autodesk.Revit.UI.Result.Cancelled;
			}
			return result;
		}

		private Application m_app;

		private Document m_doc;
	}
}
